package tcln.gxtx.client.widget.treegrid;

import com.extjs.gxt.ui.client.data.ModelData;
import com.extjs.gxt.ui.client.widget.treegrid.CellTreeGridSelectionModel;

/**
 * A special version of treegrid cell selection model which is optimized for <b>fast</b> selection of cells.
 * 
 * @param <M>
 * @author Truong Chau Lien Ngoc (lienngoc@gmail.com)
 */
public class FastTreeCellSelectionModel<M extends ModelData> extends CellTreeGridSelectionModel<M> {

    /**
     * {@inheritDoc}
     */
    @Override
    public void selectCell(int row, int cell) {
        if (selection == null || selection.row != row || selection.cell != cell) {
            super.selectCell(row, cell);
        }
    }
}
